package LesThreads;

public class Ecrit1 extends Thread {
	private String texte;
	private long attente;
	public Ecrit1 (String texte, long attente){
		this.texte = texte;
		this.attente = attente;
	}
	public void run(){
		try {
			while(true){
				if(interrupted()) return;
				System.out.print(texte);
				sleep(attente);
			}
		} catch (InterruptedException e) {
			// TODO: handle exception
			return;
		}
	}
}
